package org.msfj.hospital.model;

import java.io.Serializable;
import javax.persistence.*;
import org.msfj.common.base.BaseModel;

@Table(name = "hospital_expert")
public class HospitalExpert extends BaseModel implements Serializable {
    /**
     * 科室编号
     */
    @Column(name = "dept_id")
    private String deptId;

    /**
     * 专家姓名
     */
    @Column(name = "name_")
    private String name;

    /**
     * 职称
     */
    @Column(name = "title_")
    private String title;

    /**
     * 联系电话
     */
    @Column(name = "phone_")
    private String phone;

    /**
     * 照片
     */
    @Column(name = "photo_")
    private String photo;

    /**
     * 科室起点位置
     */
    @Column(name = "start_pic")
    private String startPic;

    /**
     * 科室终点位置
     */
    @Column(name = "end_pic")
    private String endPic;

    /**
     * 擅长
     */
    @Column(name = "be_good_at")
    private String beGoodAt;

    /**
     * 专家简介
     */
    @Column(name = "introduction_")
    private String introduction;

    private static final long serialVersionUID = 1L;

    /**
     * 获取科室编号
     *
     * @return dept_id - 科室编号
     */
    public String getDeptId() {
        return deptId;
    }

    /**
     * 设置科室编号
     *
     * @param deptId 科室编号
     */
    public void setDeptId(String deptId) {
        this.deptId = deptId == null ? null : deptId.trim();
    }

    /**
     * 获取专家姓名
     *
     * @return name_ - 专家姓名
     */
    public String getName() {
        return name;
    }

    /**
     * 设置专家姓名
     *
     * @param name 专家姓名
     */
    public void setName(String name) {
        this.name = name == null ? null : name.trim();
    }

    /**
     * 获取职称
     *
     * @return title_ - 职称
     */
    public String getTitle() {
        return title;
    }

    /**
     * 设置职称
     *
     * @param title 职称
     */
    public void setTitle(String title) {
        this.title = title == null ? null : title.trim();
    }

    /**
     * 获取联系电话
     *
     * @return phone_ - 联系电话
     */
    public String getPhone() {
        return phone;
    }

    /**
     * 设置联系电话
     *
     * @param phone 联系电话
     */
    public void setPhone(String phone) {
        this.phone = phone == null ? null : phone.trim();
    }

    /**
     * 获取照片
     *
     * @return photo_ - 照片
     */
    public String getPhoto() {
        return photo;
    }

    /**
     * 设置照片
     *
     * @param photo 照片
     */
    public void setPhoto(String photo) {
        this.photo = photo == null ? null : photo.trim();
    }

    /**
     * 获取科室起点位置
     *
     * @return start_pic - 科室起点位置
     */
    public String getStartPic() {
        return startPic;
    }

    /**
     * 设置科室起点位置
     *
     * @param startPic 科室起点位置
     */
    public void setStartPic(String startPic) {
        this.startPic = startPic == null ? null : startPic.trim();
    }

    /**
     * 获取科室终点位置
     *
     * @return end_pic - 科室终点位置
     */
    public String getEndPic() {
        return endPic;
    }

    /**
     * 设置科室终点位置
     *
     * @param endPic 科室终点位置
     */
    public void setEndPic(String endPic) {
        this.endPic = endPic == null ? null : endPic.trim();
    }

    /**
     * 获取擅长
     *
     * @return be_good_at - 擅长
     */
    public String getBeGoodAt() {
        return beGoodAt;
    }

    /**
     * 设置擅长
     *
     * @param beGoodAt 擅长
     */
    public void setBeGoodAt(String beGoodAt) {
        this.beGoodAt = beGoodAt == null ? null : beGoodAt.trim();
    }

    /**
     * 获取专家简介
     *
     * @return introduction_ - 专家简介
     */
    public String getIntroduction() {
        return introduction;
    }

    /**
     * 设置专家简介
     *
     * @param introduction 专家简介
     */
    public void setIntroduction(String introduction) {
        this.introduction = introduction == null ? null : introduction.trim();
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        HospitalExpert other = (HospitalExpert) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getDeptId() == null ? other.getDeptId() == null : this.getDeptId().equals(other.getDeptId()))
            && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
            && (this.getTitle() == null ? other.getTitle() == null : this.getTitle().equals(other.getTitle()))
            && (this.getPhone() == null ? other.getPhone() == null : this.getPhone().equals(other.getPhone()))
            && (this.getPhoto() == null ? other.getPhoto() == null : this.getPhoto().equals(other.getPhoto()))
            && (this.getStartPic() == null ? other.getStartPic() == null : this.getStartPic().equals(other.getStartPic()))
            && (this.getEndPic() == null ? other.getEndPic() == null : this.getEndPic().equals(other.getEndPic()))
            && (this.getBeGoodAt() == null ? other.getBeGoodAt() == null : this.getBeGoodAt().equals(other.getBeGoodAt()))
            && (this.getEnable() == null ? other.getEnable() == null : this.getEnable().equals(other.getEnable()))
            && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
            && (this.getCreateBy() == null ? other.getCreateBy() == null : this.getCreateBy().equals(other.getCreateBy()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateBy() == null ? other.getUpdateBy() == null : this.getUpdateBy().equals(other.getUpdateBy()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
            && (this.getIntroduction() == null ? other.getIntroduction() == null : this.getIntroduction().equals(other.getIntroduction()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getDeptId() == null) ? 0 : getDeptId().hashCode());
        result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
        result = prime * result + ((getTitle() == null) ? 0 : getTitle().hashCode());
        result = prime * result + ((getPhone() == null) ? 0 : getPhone().hashCode());
        result = prime * result + ((getPhoto() == null) ? 0 : getPhoto().hashCode());
        result = prime * result + ((getStartPic() == null) ? 0 : getStartPic().hashCode());
        result = prime * result + ((getEndPic() == null) ? 0 : getEndPic().hashCode());
        result = prime * result + ((getBeGoodAt() == null) ? 0 : getBeGoodAt().hashCode());
        result = prime * result + ((getEnable() == null) ? 0 : getEnable().hashCode());
        result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
        result = prime * result + ((getCreateBy() == null) ? 0 : getCreateBy().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateBy() == null) ? 0 : getUpdateBy().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getIntroduction() == null) ? 0 : getIntroduction().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", deptId=").append(deptId);
        sb.append(", name=").append(name);
        sb.append(", title=").append(title);
        sb.append(", phone=").append(phone);
        sb.append(", photo=").append(photo);
        sb.append(", startPic=").append(startPic);
        sb.append(", endPic=").append(endPic);
        sb.append(", beGoodAt=").append(beGoodAt);
        sb.append(", introduction=").append(introduction);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}